import request from '@/utils/request'

// 查询各类设备统计数量
export function getDeviceCount() {
  return request({
    url: '/iim/Map/getDeviceCount',
    method: 'get'
  })
}

// 查询机柜对象列表
export function listDeviceRack(query) {
  return request({
    url: '/iim/deviceRack/list',
    method: 'get',
    data: query
  })
}

// 查询管理单元对象列表
export function listDeviceImu(query) {
  return request({
    url: '/iim/deviceImu/list',
    method: 'get',
    data: query
  })
}

// 查询交换机对象列表
export function listDeviceSwitch(query) {
  return request({
    url: '/iim/deviceSwitch/list',
    method: 'get',
    data: query
  })
}

// 查询配线架对象列表
export function listDeviceDistributionFrame(query) {
  return request({
    url: '/iim/deviceDistributionFrame/list',
    method: 'get',
    data: query
  })
}

// 查询信息点对象列表
export function listDeviceAp(query) {
  return request({
    url: '/iim/deviceAp/list',
    method: 'get',
    data: query
  })
}

// 查询机柜对象详细
export function getDeviceRack(id) {
  return request({
    url: '/iim/deviceRack/' + id,
    method: 'get'
  })
}

// 查询管理单元对象详细
export function getDeviceImu(id) {
  return request({
    url: '/iim/deviceImu/' + id,
    method: 'get'
  })
}

// 查询交换机对象详细
export function getDeviceSwitch(id) {
  return request({
    url: '/iim/deviceSwitch/' + id,
    method: 'get'
  })
}

// 查询配线架对象详细
export function getDeviceDistributionFrame(id) {
  return request({
    url: '/iim/deviceDistributionFrame/' + id,
    method: 'get'
  })
}

// 查询信息点对象详细
export function getDeviceAp(id) {
  return request({
    url: '/iim/deviceAp/' + id,
    method: 'get'
  })
}

// 查询设备端口对象列表
export function listDevicePort(query) {
  return request({
    url: '/iim/devicePort/list',
    method: 'get',
    data: query
  })
}

//查询端口链路
export function getPortLink(query) {
  return request({
    url: '/system/link/getLink',
    method: 'get',
    data: query
  })
}